<!doctype html>
<html>
<head>
<meta charset="utf-8">
<link rel="stylesheet" type="text/css" href="/resource/admin/css/admin.css" media="all" />
<link rel="stylesheet" type="text/css" href="/resource/static/h-ui/css/H-ui.min.css" />
<link rel="stylesheet" type="text/css" href="/resource/static/h-ui.admin/css/H-ui.admin.css" />
<link rel="stylesheet" type="text/css" href="/resource/lib/Hui-iconfont/1.0.9/iconfont.css" />
<script type="text/javascript" src="/resource/common/js/jquery-1.12.3.min.js"></script>
<script type="text/javascript" src="/resource/admin/plugs/layer/layer.js"></script>
<script type="text/javascript" src="/resource/admin/plugs/laydate/laydate.js"></script>
<script type="text/javascript" src="/resource/admin/js/info.js"></script>
<title>基本设置</title>
<style type="text/css">
.form-table th, .form-table td {
	border: 1px #eee solid;
	height: 50px;
	padding: 0 10px;
}
.form-table thead th {
	color: #555;
	font-weight: 600;
}
.form-table td:first-child {
	font-weight: 600;
	color: #666;
	text-align: right;
}
.form-table td input[type='text'], .form-table td input[type='password'], .form-table td input[type='number'], .form-table td textarea {
	background-color: #fff;
	border-radius: 3px;
	border: 1px #ddd solid;
	height: 36px;
	min-width: 250px;
	padding: 0 10px;
}
.form-table td textarea {
	background-color: #fff;
	border-radius: 3px;
	border: 1px #ddd solid;
	height: 80px;
	min-width: 250px;
	padding: 0 10px;
}
.form-table td button,.form-table th button {
	background: #1e9fff;
	height: 36px;
	padding: 5px 15px;
	border-radius: 4px;
	border: 0;
	color: #fff;
	font-weight: 600;
	font-size: 14px;
}
.form-table td span {
	margin-left: 10px;
	color: red;
}
.form-table tbody tr:hover {
	background-color: #f9f9f9;
}
</style>
</head>
<body>
	<nav class="breadcrumb">
		<i class="Hui-iconfont">&#xe67f;</i>首页
		<span class="c-gray en">&gt;</span>平台信息
		<a class="btn btn-success radius r" style="line-height:1.6em;margin-top:3px" href="javascript:location.replace(location.href);" title="刷新" >
			<i class="Hui-iconfont">&#xe68f;</i>
		</a>
	</nav>
	<div style="padding: 30px">
		<!-- 商家信息 -->
		<table width="100%" class="form-table">
			<thead>
				<tr align="center">
					<th colspan="2">
						<h4 style="display:inline;">商家信息</h4>
						<h5 style="display:inline;color:red;margin-left: 20px;">
							*只有审核认证通过后方可正常使用，回调域名仅限资料里面提交的域名
						</h5>
					</th>
				</tr>
			</thead>
			<tbody>
				<tr>
					<td width="20%">商户号</td>
					<td>
						{$info.merchantid}
					</td>
				</tr>
				<tr>
					<td>注册时间</td>
					<td>
						{if $info.reg_time}
						{$info.reg_time|date='Y-m-d H:i:s'}
						{/if}
					</td>
				</tr>
				<tr>
					<td>联系电话</td>
					<td>
						{if !$info.phone}
						<button class="button" onClick="bind_info('bindPhone')">绑定</button>
						{else /}
						{$info.phone}
						{/if}
					</td>
				</tr>
				<tr>
					<td>邮箱</td>
					<td>
						{if !$info.mail}
						<button class="button" onClick="bind_info('bindMail')">绑定</button>
						{else /}
						{$info.mail}&nbsp;&nbsp;&nbsp;
						<button class="button" onClick="bind_info('bindMail')">改绑</button>
						{/if}
					</td>
				</tr>
				<tr>
					<td>设置密码</td>
					<td>
						<button class="button edit_pwd">修改密码</button>
						<button class="button set_pay_pwd">设置交易密码</button>
					</td>
				</tr>
				<tr>
					<td>设置APIKey</td>
					<td>
						{if !$info.merchantkey}
						<button class="button set_apikey">生成</button>
						{else /}
						<button class="button look_apikey">查看</button>
						{/if}
					</td>
				</tr>
				<tr>
					<td>资质认证</td>
					<td>
						<h5 style="display:inline;font-weight:bolder;margin-right:20px;color:{switch $info.status}
								{case 1}blue{/case}
								{case 2}#999{/case}
								{case 4}red{/case}
								{default /}green
							{/switch};">
							{switch $info.status}
								{case 1}已认证{/case}
								{case 2}审核中{/case}
								{case 4}审核失败{/case}
								{default /}未认证
							{/switch}
						</h5>
						{if $info.status eq 3}
						<button class="button verify_syb">提交</button>
						{/if}
						{if $info.status eq 4}						
						<h5 style="display:inline;color:red;margin-left: 20px;">{$info.verify}</h5>
						{/if}
					</td>
				</tr>
				<tr>
					<td>其他信息</td>
					<td>
						<button class="button look_me">查看</button>
					</td>
				</tr>
			</tbody>
			<!-- 费率 -->
			<thead>
				<tr align="center">
					<th colspan="2">
						<h4>费率</h4>
					</th>
				</tr>
			</thead>
			<tbody>
				<tr>
					<td>支付宝充值费率</td>
					<td>
						充值范围：{$setting.m_alipay_recharge_min}-{$setting.m_alipay_recharge_max} 费率：{$info.alipay_fee/100}
					</td>
				</tr>
				<tr>
					<td>微信充值费率</td>
					<td>
						充值范围：{$setting.m_wechat_recharge_min}-{$setting.m_wechat_recharge_max} 费率：{$info.wechat_fee/100}
					</td>
				</tr>
				<tr>
					<td>银行卡下发费率</td>
					<td>
						充值范围：{$setting.m_bank_recharge_min}-{$setting.m_bank_recharge_max} 费率：{$info.bank_fee/100}
					</td>
				</tr>
			</tbody>
		</table>
		<!-- 收付款管理 -->
		<table width="100%" class="form-table" style="margin:30px 0;">
			<thead>
				<tr align="center">
					<th colspan="5">
						<h4 style="float:left;">收付款管理</h4>						
						<button class="button bind_bankcard" style="float:right;">绑定账号</button>
						<div style="clear: both;"></div>
					</th>
				</tr>
				<tr align="center">
					<th>银行卡帐号</th>
					<th>持卡人姓名</th>
					<th>开户银行</th>
				</tr>
			</thead>
			<tbody>
				{if $bank}
				{foreach $bank as $key=>$value}
				<tr>
					<td style="text-align: left;font-weight: normal;">{$value.card_number}</td>
					<td>{$value.card_name}</td>
					<td>{$value.bank_name}</td>
				</tr>
				{/foreach}
				{else /}
				<tr>
					<td colspan="3" style="text-align: center;font-weight: normal;color: #999">暂无数据</td>
				</tr>
				{/if}
			</tbody>
		</table>
	</div>
</body>
</html>